<template>
  <el-dialog
    title="修改地址"
    :visible.sync="editDialogVisible"
    width="50%"
    @close="editDialogClose">

    <!-- 内容 -->
    <order-edit-dialog-form></order-edit-dialog-form>

    <!-- 按钮 -->
    <span slot="footer">
      <el-button @click="editDialogVisible = false">取 消</el-button>
      <el-button type="primary" @click="editDialogVisible = false">确 定</el-button>
    </span>

  </el-dialog>
</template>

<script>
// 组件
  import OrderEditDialogForm from '@/views/Main/order/orderCompent/OrderEditDialogForm';

export default {
  data() {
    return {
      editDialogVisible: false, // dialog控制器
    }
  },
  methods: {
    openEidtDialog() { // 开启dialog
      this.editDialogVisible = true;
    },
    editDialogClose() { // 关闭dialog回调
      // 发送表单清空验证事件
      this.$bus.$emit('editFormRest');
    }

  },
  created() {
    this.$bus.$on('openEidtDialog', this.openEidtDialog);
  },
  destroyed() {
    this.$bus.$off('openEidtDialog');
  },
  components: {
    OrderEditDialogForm
  }
}
</script>

<style lang="scss" scoped>
</style>